package com.sinocare.project.common.entity;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;

/**
 * 连锁药店表(SccDrugstore)表实体类
 *
 * @author makejava
 * @since 2021-12-20 18:55:28
 */
@Data
@SuppressWarnings("serial")
@TableName(value = "scc_drugstore")
public class SccDrugstore extends Model<SccDrugstore> {
    //主键，药店id
    @TableId(value = "store_id",type = IdType.AUTO)
    private Integer storeId;
    //店铺名称
    private String storeName;
    //店铺编码
    private String storeCode;
    //总店编号
    private String parentCode;
    //省编号
    private Integer provinceCode;
    //省
    private String province;
    //市编号
    private Integer cityCode;
    //市
    private String city;
    //区/县编号
    private Integer countyCode;
    //区/县名称
    private String county;
    //详细地址
    private String addressDetall;
    //创建时间
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    private Date createTime;
    //修改时间
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(pattern = "yyyy-MM-dd",timezone = "GMT+8")
    private Date updateTime;
    @TableField(exist = false)
    private SncUserLogin sncUserLogin;
    /**
     * 获取主键值
     *
     * @return 主键值
     */
    @Override
    public Serializable pkVal() {
        return this.storeId;
    }
}

